<!--
 * @Descripttion: 出手鸭小程序
 * @version:1.0.1 
 * @Author: HHL
 * @Date: 2023-10-08 14:17:03
 * @LastEditTime: 2025-09-17 20:22:34
 * @LastEditors: sueRimn
-->


<template>
  <view class="action-list">
      <view class="item d-flex justify-content-between align-items-center" @click="handleKefu()">
      <view class="d-flex align-items-center justify-content-center">
        <view class="base-icons kefu1-icon" />
        <view class="text">客服中心</view>
      </view>
      <uni-icons type="right" size="16" color="#a8a8a8" />
    </view>
    <view class="item d-flex justify-content-between align-items-center" @click="handleJumpPage(item)"
      v-for="(item, index) in actionList" :key="index">
      <view class="d-flex align-items-center justify-content-center">
        <view class="base-icons" :class="item.icon" />
        <view class="text">{{ item.name }}</view>
      </view>
      <uni-icons type="right" size="16" color="#a8a8a8" />
    </view>

  </view>
</template>


<script>
import { urlJump } from '@/utils'
export default {
  data() {
    return {
      actionList: [
        // { id: 2, "name": "领券中心", "icon": "quan-icon", url: "/pages/category/index", "type": "jump" },
        { id: 3, "name": "意见反馈", "icon": "yijian-icon", url: "/pages/feedback/index", "type": "jump" },
        { id: 4, "name": "设置", "icon": "shezhi-icon", url: "/pages/setting/index", "type": "jump" },




      ]
    }
  },
  methods: {
    handleJumpPage(item) {
      if (item.type == "kefu") {
        console.log("kefu")
      } else {
        this.$emit('checkAuth', () => {
          console.log(item)
          uni.navigateTo({ url: item.url })
        })
      }
    },
    handleKefu(){
      urlJump({ routeType: 2, target:        'https%3a%2f%2fszcskjyxgszj.qiyukf.com%2fclient%3fk%3d0e53e1b92d44e6d4ce46772a56d87068%26wp%3d1%26robotShuntSwitch%3d0%26shuntId%3d0%26language%3dzh-cn%26templateId%3d8131497'
 })
      // window.location.href="https%3a%2f%2fszcskjyxgszj.qiyukf.com%2fclient%3fk%3d0e53e1b92d44e6d4ce46772a56d87068%26wp%3d1%26robotShuntSwitch%3d0%26shuntId%3d0%26language%3dzh-cn%26templateId%3d8131497"
    }
  }
}
</script>

<style lang="scss" scoped>
.action-list {
  background: #fff;
  border-radius: 24rpx;
  margin: 24rpx 32rpx;
  position: relative;
  .kefu-icon{
      width: 32rpx;
    }
  .item {
    height: 118rpx;
    margin: 0 32rpx;
    border-bottom: #fdfdfd 1rpx solid;

    

    .text {
      color: var(--hui-color-title);
      font-size: var(--hui-font-size-28);
      margin: 0rpx 0 0 12rpx;
    }
  }

}</style>